package com.example.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.entity.Classification;
import com.example.entity.vo.ClassificationVo;
import com.example.mapper.ClassificationMapper;
import com.example.service.IClassificationService;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

/**
 * <p>
 *  服务实现类
 * </p>
 *
 * @author jobob
 * @since 2024-09-09
 */
@Service
public class ClassificationServiceImpl extends ServiceImpl<ClassificationMapper, Classification> implements IClassificationService {

    @Resource
    ClassificationMapper classificationMapper;

    @Override
    public ClassificationVo selectAllByCommodityCategory(Integer id) {
        return classificationMapper.selectAllByCommodityCategory(id);
    }

    @Override
    public List<ClassificationVo> selectAllByCommodityId(Integer id) {
        return classificationMapper.selectAllByCommodityId(id);
    }

}
